﻿using Autofac;
using Rapattern.interfaces;
using Rapattern.Services;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace Rapattern.App
{
    public partial class FrmMain : Form
    {
        private IEmployeeRepository _employeeRepository;

        public FrmMain()
        {
            InitializeComponent();
            this._employeeRepository = MemoryInfo.StoreContainer.Resolve<IEmployeeRepository>();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            var result = _employeeRepository.ModifyEmployee(null);
        }

        private void button2_Click(object sender, EventArgs e)
        {
            this._employeeRepository = MemoryInfo.StoreContainer.Resolve<IEmployeeRepository>();
            var result = _employeeRepository.ModifyEmployee(null);
        }
    }
}
